package com.chzc.fm.duotin.ui.more;

import android.app.Activity;
import android.app.AlertDialog;
import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothDevice;
import android.content.DialogInterface;
import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.Button;
import android.widget.LinearLayout;
import android.widget.ListView;
import android.widget.Toast;

import com.chzc.fm.duotin.R;

import java.util.ArrayList;
import java.util.Set;

public class Carlistenbaby extends Activity {
     private LinearLayout bluetooth;
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_carlistenbaby);
        bluetooth=(LinearLayout)findViewById(R.id.bluetooth) ;
        bluetooth.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                new AlertDialog.Builder(Carlistenbaby.this)
                        .setTitle("某应用想打开蓝牙")
                        //  .setMessage("清除缓存，可以增加手机内存；再次收听，需要重新消耗流量")
                        .setPositiveButton("拒绝",new DialogInterface.OnClickListener() {
                            @Override
                            public void onClick(DialogInterface dialog,int which) {
                                //   DataCleanManager dataCleanManager=new DataCleanManager();

                            }
                        })
                        .setNegativeButton("允许",new DialogInterface.OnClickListener() {
                            @Override
                            public void onClick(DialogInterface dialog,int which) {
                                // TODO Auto-generated method stub

                            }
                        }).show();
            }
        });

    }

}
